package cn.edu.scau.cmi.guihao.client;

import cn.edu.scau.cmi.guihao.interProgramming.exmple.AnimalBehavior;
import cn.edu.scau.cmi.guihao.interProgramming.exmple.Cat;
import cn.edu.scau.cmi.guihao.interProgramming.exmple.Dog;
import cn.edu.scau.cmi.guihao.pane.InterfaceProgrammingPane;
import cn.edu.scau.cmi.guihao.pane.ObjectAdapterPane;
import javafx.application.Application;
import javafx.event.EventHandler;
import javafx.scene.Scene;
import javafx.stage.Stage;
import javafx.stage.WindowEvent;

public class InterProgrammingClient extends Application{
	@Override
	public void start(Stage primaryStage) {
		try {
			Scene scene = new Scene(new InterfaceProgrammingPane());
			primaryStage.setScene(scene);
			primaryStage.show();
			primaryStage.setOnCloseRequest(new EventHandler<WindowEvent>() {
			      @Override
			      public void handle(WindowEvent event) {
			    	  System.exit(0);
			      }
			});
		} catch(Exception e) {
			e.printStackTrace();
		}
	}
	
	public static void main(String[] args) {
		launch(args);
	}
}
